<script context="module" lang="ts">
	export const prerender = true;
</script>

<script lang="ts">
	let a = 0
</script>

<div class="space-y-3">
	<div>
		{a}
		<div class="space-x-3">
			<button class="btn" on:click={() => a--}>-</button>
			<button class="btn" on:click={() => a++}>+</button>
		</div>
	</div>
	<div>
		<!-- The button to open modal -->
		<label for="my-modal-6" class="btn modal-button">open modal</label>

		<!-- Put this part before </body> tag -->
		<input type="checkbox" id="my-modal-6" class="modal-toggle" />
		<div class="modal modal-bottom sm:modal-middle">
			<div class="modal-box">
				<h3 class="font-bold text-lg">Congratulations random Internet user!</h3>
				<p class="py-4">You've been selected for a chance to get one year of subscription to use Wikipedia for free!</p>
				<div class="modal-action">
					<label for="my-modal-6" class="btn">Yay!</label>
				</div>
			</div>
		</div>
	</div>
</div>
